package com.sunxiansheng.home;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.ComponentScan;

/**
 * Description: 首页微服务启动类
 * @Author sun
 * @Create 2024/7/8 16:56
 * @Version 1.0
 */
@SpringBootApplication
@MapperScan(value = "com.sunxiansheng.*.mapper") // 扫描 Mapper 接口
@ComponentScan(value = "com.sunxiansheng") // 扫描组件
@EnableFeignClients(basePackages = "com.sunxiansheng") // 开启 Feign 客户端
public class HomeApplicaion {
    public static void main(String[] args) {
        // 异步日志配置
        System.setProperty("Log4jContextSelector", "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector");
        SpringApplication.run(HomeApplicaion.class, args);
    }
}